<?
	class OptionTypesBO extends BusinessObject {

		function setAttributes(){
	    	$this->fields = array (
									id => otpID,
									otpName  => otpName ,
									otpDescription  => otpDescription ,
									otpType  => otpType,
									otpOrder => otpOrder 
									);
			BusinessObject::setAttributes();
		}

		function OptionTypesBO () {
			BusinessObject::BusinessObject("optiontypes");
			$this->setAttributes();
		}

   function get_types_as_html($sel_typeID=""){
    $ret = "";
    $this->Load(0,0);    
    while ($this->Next()) 
    {
      $ret.= "<option value='".$this->id."' ".(($sel_typeID==$this->id)?"selected":"").">".htmlspecialchars($this->otpName)."</option>";
    }
    return $ret;
  }
		
	}
?>
